package com.lei.design.singleton;

/**
 * @Author LeiXiaoLei
 * @Date 2022/5/20 09:31
 * @Version 1.0
 */
public class Main {
    public static void main(String[] args) {
        new Thread(() -> {
            Singleton1 instance1 = Singleton1.getInstance();
            System.out.println(instance1);
        }).start();
        new Thread(() -> {
            Singleton1 instance2 = Singleton1.getInstance();
            System.out.println(instance2);
        }).start();
        new Thread(() -> {
            Singleton1 instance3 = Singleton1.getInstance();
            System.out.println(instance3);
        }).start();
        new Thread(() -> {
            Singleton1 instance4 = Singleton1.getInstance();
            System.out.println(instance4);
        }).start();

    }
}
